#include "mycoin.h"
#include<Qdebug>
//MyCoin::MyCoin(QWidget *parent) : QPushButton(parent)
//{


//}
MyCoin::MyCoin(QString btnImg)
{
    QPixmap pix;
    bool ret=pix.load(btnImg);
    if(!ret)
    {
        QString str = QString("图片%1加载失败").arg(btnImg);
        qDebug()<<str;
                  return;
    }
    this->setFixedSize(pix.width(),pix.height());
    this->setStyleSheet("QPushButton(border:0px;)");
    this->setIcon(pix);
    this->setIconSize(QSize(pix.width(),pix.height()));

}
